<?php

class Home_Controller extends Controller {

    function index()
    {
	$test = new Home_Model();
	
	$test->load(1);
	$test->to_string();
	echo '<br/>count : ' . Home_Model::count().'<br/>';
	$tests = Home_Model::all();
	foreach ($tests as $t)
	{
	    $t->to_string();
	}
	if(count($this->params) > 0)
	{
	    $this->view->set('name', $this->params[0]);
	    $this->view->set('name2', $this->params[1]);
	}
	else
	{
	    $this->view->set('name','Mario');
	$this->view->set('name2','Friz');
	}
	$this->view->render('index');
    }

}